<template>
  <div>
    <input type="text" :placeholder="palceholder" v-model="content" />
  </div>
</template>

<script>
export default {
  name: "Todoinput",

  data() {
    return {
      content: "",
    };
  },
  inject: ["palceholder"],
  mounted() {},

  methods: {
    reset() {
      this.content = "";
    },
  },
  watch: {
    content() {
      if (this.content.length > 0) {
        this.$emit("changeContent", this.content);
      }
    },
  },
};
</script>

<style lang="scss" scoped>
</style>